Repository navigation
kb: register the KB embedder and reranker; reranker template in config/ - #17
Merged
Merged
Conversation
- models.toml: the kb-emb-qwen3-8b (:8021) and kb-rr-qwen3-4b (:8029) pooling entries that the hub's knowledge base names, as the box runs them. Until now they existed only in the deployed checkout's uncommitted models.toml. The reranker's --chat-template now points at config/qwen3_reranker.jinja instead of a scratch folder. - config/qwen3_reranker.jinja: vLLM v0.32.0's template, byte-identical to the file the box serves today (sha256 e1ee98e6...). - wire: a model served with --runner pooling answers /v1/embeddings or /v1/rerank and never chat completions, so no client config lists it, and a Kimi table that servedeck wrote for one is retired. Without this, `servedeck wire` would add both models to VS Code and Kimi as chat models. - tests: the registry pins now count 9 models. A new test shows that neither VS Code nor Kimi lists a pooling model, and that a stale Kimi table is retired; it fails on the old wire.py.
…ling spelling Review fixes on the KB block: - discovery: Qwen3ForCausalLM, the architecture of both KB checkpoints, is a known one (label qwen3; the map stays 1:1). Unmapped, doctor failed both weights rows and the dashboard offered neither, though both were complete in the hub cache. - wire: a model is a pooling model for --runner pooling or --convert embed|classify|reward, written with a space or with =, the last value winning as in vLLM's argparse. Before, only the two-token --runner pooling was seen. - tests: the KB checkpoints are servable; nine flag spellings, each wired exactly when it chats; the reranker's chat template is a file this repo keeps. - docs: Kimi gets a table per chat model; the one embedder here is the KB's; the flags row names the pooling spellings. - models.toml comments: no private paths, 8.04 GB, the VRAM budgets marked as estimates, and the 32,304 MiB the pair holds beside a main model.
The guard now also turns red when the repo copy drifts from vLLM v0.32.0's qwen3_reranker.jinja, not only when the file is gone.
pctablet505
marked this pull request as ready for review
November 21, 2026 13:17
pctablet505
added a commit
that referenced
this pull request
Dec 3, 2026
Both sides appended at the same places: the Nemotron entry and the KB pair are both kept in models.toml, discovery's architecture map and their tests; the registry now has 10 models and wire lists 12 ids (the KB pooling models never).
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
models.toml: the two pooling models the hub's knowledge base uses.kb-emb-qwen3-8b: Qwen3-Embedding-8B on :8021.kb-rr-qwen3-4b: Qwen3-Reranker-4B on :8029.models.toml.--chat-templatenow points atconfig/qwen3_reranker.jinjainstead ofa scratch folder.
the VRAM budgets are estimates.
config/qwen3_reranker.jinja: vLLM v0.32.0's template, byte-identical to the file the reranker reads today(sha256
e1ee98e69aab7b2d…).servedeck/wire.py: a pooling model answers/v1/embeddingsor/v1/rerank, never chat completions.--runner pooling, or with--convert embed|classify|reward, writtenwith a space or with
=. As in vLLM's argparse, the last value wins.wireleaves such a model out of the VS Code and Kimi configs, and retires a Kimi table that servedeck wrote forone earlier. Codex output is unchanged, because it reads main-slot models only.
servedeck/discovery.py:Qwen3ForCausalLM, the architecture of both KB checkpoints, is now a knownarchitecture, with its own label
qwen3, so the map stays 1:1.doctorfailed both weights rows, and the dashboard offered neither model, even though both werecomplete in the hub cache.
CLIENTS.md: Kimi gets one table per chat model, and the one embedder on the box is the KB's.CONFIGURATION.md: theflagsrow names the pooling spellings.Deterministic gate
Each tree ran with its own editable
.venv, as in CI, through the box's test scheduler with 4 workers and the sameinvocation every time.
wire.pyagainst this branch's registry and tests: 2 failed;_chatsalways true;_chats(--runnerpresent means pooling);=spelling;embednot counted as pooling;mkdocs build --strictwith out-of-tree output exits 0.Review gate
Pass-1, author-blind diff audit (a fresh reviewer with no authoring history, which read no PR prose): no Blocker,
3 Warnings, 6 Nits.
Pass-2, what happened to each finding:
Qwen3ForCausalLMnot inKNOWN_ARCHS)test_the_knowledge_base_pooling_checkpoints_are_servablefails before the fix and passes after; the mutant that removes the entry turns 2 tests red_chatsmisses--runner=poolingand--convert embed, and a loose_chatssurvived the teststest_a_model_is_wired_unless_its_flags_make_it_a_pooling_model: 5 cases fail before the fix; 4 mutants red, including the loose oneCLIENTS.md,CONFIGURATION.mdmodels.tomlcomment, 32,304 MiB = ceil(97887 × 0.21) + ceil(97887 × 0.12)Why the template path stands (Warning 1):
models.tomlis the daemon. It readsPROJECT_ROOT / "models.toml"(servedeck/settings.py:47,:141).servedeck.serviceruns withWorkingDirectory=%h/Projects/servedeckandExecStart=%h/Projects/servedeck/.venv/bin/python -m servedeck, and sets noSERVEDECK_MODELS.models.tomlthat holds the flag, and this commit adds bothtogether.
models.tomlalready holds host paths for this box (:375-378,:593).test_the_kb_reranker_chat_template_is_a_file_this_repo_keepspins the path and the file's sha256. A one-byte changeturns it red.
Confirm pass (the same reviewer, on the fix commit only): ACCEPT, with two Nits.
servedeck startacting directly from another checkout, or aSERVEDECK_MODELSoverride,reads that checkout's
models.tomlwhile the flag names the control plane's file. Noted, not changed. After the mergeboth copies are the same file.
The reviewer's own run of the suite, without the 4 e2e modules, gave 1,297 passed, 23 skipped, 0 failed. My counts
include those modules, which skip in the sandbox.
Follow-ups (not in this PR)
servedeck/gateway.py:553-561): a request that names no model goes tolive[0]when the main slot is down. With only a KB resident live, that request reaches a pooling engine./v1/modelsalso lists the pooling ids when they are live. The deployed box behaves the same way today, because thesame entries already sit in its
models.toml.COULD NOT VERIFY
vram_mibbudgets are enough at 8,192 context and 16,384 batched tokens./v1/embeddingsthrough the gateway for the embedder. The hub calls the model's port directly.Deploy (not done; the owner's)
models.tomlholds thesame two entries with the old template path. Drop that copy when updating, or the tables clash.
models.tomlonly at start:servedeck stop kb-rr-qwen3-4bif it is running;servedeck.service, but only when no client is using the gateway;servedeck start kb-rr-qwen3-4bwhen the KB needs it.ps -eo argsfor the reranker's vLLM process showsconfig/qwen3_reranker.jinja;/v1/rerankcall on :8029 answers;servedeck doctorshows both weights rows OK.